class GBErr(Exception):
    def __init__(self, errcode, errmsg=None):
        self.errcode = errcode
        self.errmsg = errmsg

        super(GBErr, self).__init__()

# def ERR(errcode, msg):
#     return GBErr(errcode, msg)


errOK = GBErr(1, "SUCCESS")
errException = GBErr(2, "")
errNotImplemented = GBErr(3, "")
errIllegalObject = GBErr(4, "")
errPermissionDenied = GBErr(5, "")
errInvalidArguments = GBErr(2, "invalid arguments")
errObjectDoesNotExist = GBErr(6, "")
errObjectDoesExist = GBErr(7, "")
errPathNotFound = GBErr(8, "")

